<%@ page contentType="text/html; charset=UTF-8"%>
<%@ include file="/commons/taglibs.jsp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title><s:text name="horseadimn"/></title>
<script type="text/javascript" src="${ctx}/scripts/commons/jquery-1.2.3.pack.js"></script>
<script type="text/javascript" src="${ctx}/scripts/datepicker/WdatePicker.js"></script>
<script type="text/javascript">
     
     
     //过滤特殊字符
function checkStr(str){
	if(str.value!=""){
	      if (!(/^[^\|"'<>:;：；‘“$%*@,.，。/、！·#￥%……—*（）——+| ]*$/.test(str))){
	      		return false;
	      }
	}
	return true;
}
function deleteProductBuyer(buyerId) {
	  if(window.confirm('确定要删除吗?')) {
	  		window.location = "${ctx }/product/productBuyer!delete.action?buyerId="+buyerId+"&flipData.page=<s:property value="flipData.page" />";
	  }  
	}
 </script>
</head>
<link href="${ctx}/css/main/base.css" rel="stylesheet" type="text/css"/>
<link href="${ctx}/css/main/main.css" rel="stylesheet" type="text/css"/>
<body class="m_6">
<div id="main">
	<div class="zdsz" id="select1">
		<div class="tab"><a href="${ctx}/product/productBuyer!index.action"><h3 class="sel">订单列表</h3></a></div>
		<div class="zd_gut">
		<ul class="block">
		<li>
    			<table width="95%" border="0" align="center" cellpadding="0" cellspacing="0" class="tab_1 center">
				  <tr>
				 	 <td class="bg4">订单号</td>
				    <td class="bg4">订购号码</td>
				    <td class="bg4">编号</td>
				    <td class="bg4">订购人姓名</td>
				    <td class="bg4">订购人电话</td>
				    <td class="bg4">订购日期</td>
				    <td class="bg4">产品金额</td>
				    <td class="bg4">发货</td>
				    <td class="bg4">操作</td>
				  </tr>
				  <s:iterator value="flipData.data" status="buyer" id="buy">
				  <tr>
				  	<td>
					  <s:property value="buyerNo"/>
					</td>
					<td>
					  <s:property value="phoneNumber"/>
					</td>
					<td>
					  <s:property value="buyerM"/>
					</td>
					<td>
					    <a href="${ctx }/product/productBuyer!productBuyerdetail.action?buyerId=<s:property value="buyerId"/>">${buyerName }</a>
					</td>
					<td>
					    <s:property value="buyerPhone"/>
					</td>
					<td>
		                 <s:property value="buyerDate.toString().substring(0,19)" />
					</td>
					<td>
					    <s:property value="buyerPrice"/>
					</td>
					<td>
					    <s:if test="buyerRead==0">未读</s:if><s:if test="buyerRead==1">已读</s:if><s:if test="buyerRead==2">已发货</s:if><s:if test="buyerRead==3">已上架</s:if>
					</td>
					<td>
		                 <a href="${ctx }/product/productBuyer!productBuyerdetail.action?buyerId=<s:property value="buyerId"/>">[查看]</a><a href="${ctx }/product/productBuyer!productBuyerSend.action?buyerId=<s:property value="buyerId"/>">[发货]</a><a href="${ctx }/product/productBuyer!productTop.action?buyerId=<s:property value="buyerId"/>">[上架]</a><%-- <span onclick=" deleteProductBuyer('<s:property value="buyerId"/>');" style="cursor: pointer;"> [删除]</span>--%>
					</td>
					</tr>
				  </s:iterator>
		  		</table> 
              <form action="productBuyer!index.action" method="post" name="pageform">
		  			  	 <div class="fy01" align="center">
          	    <input type="hidden" value="<s:property value="flipData.page" />" name="flipData.page" id="page">
				<s:text name="index.pagebar.first"/><s:property value="flipData.total" />
				<s:text name="index.pagebar.second"/>
				<s:property value="flipData.size" />
				<s:text name="index.pagebar.third"/>
				<s:property value="flipData.page" />
				/<s:property value="flipData.totalPageCount" />
				<s:text name="index.pagebar.first"/>
				<s:property value="flipData.totalPageCount" />
				<s:text name="index.pagebar.fouth"/>　　
				 <<
				<a href="javascript:document.getElementById('page').value=1;list();"><s:text name="index.pagebar.fifth"/></a>&nbsp;&nbsp;
				<s:if test="flipData.page >1 ">
					<a href="javascript:document.getElementById('page').value=parseInt(document.getElementById('page').value)-1;list();"><s:text name="index.pagebar.priv"/></a>&nbsp;&nbsp;
                </s:if>
				<s:if test="flipData.page < flipData.totalPageCount">
					<a href="javascript:document.getElementById('page').value=parseInt(document.getElementById('page').value)+1;list();"><s:text name="index.pagebar.next"/></a>&nbsp;&nbsp;
     		    </s:if>
				<a href="javascript:<s:if test="#request.flipData.totalPageCount > 0">document.getElementById('page').value=<s:property value="#request.flipData.totalPageCount"/></s:if>;list();"><s:text name="index.pagebar.last"/></a>
				>>
				</input>	
			</div>
			</form>
</div>
</body>
</html>
<script type="text/javascript">
<!--
function issunamelist(){
document.forms[0].submit();
}

function list(){
document.forms[0].submit();
}

function issuelist(){
if( ($("input:checked").size())==0){
  			alert("<s:text name="bg.horse.choose" />");
  			return;
  }
document.forms[1].submit();
}
//-->
</script>
